package org.obs.service.impl;

import org.acegisecurity.userdetails.UserDetails;
import org.acegisecurity.userdetails.UserDetailsService;
import org.acegisecurity.userdetails.UsernameNotFoundException;
import org.obs.service.DetailsService;
import org.springframework.dao.DataAccessException;

public class UserDetailsServiceImpl implements UserDetailsService {

	private DetailsService userService;
	
	public DetailsService getUserService() {
		return userService;
	}

	public void setUserService(DetailsService userService) {
		this.userService = userService;
	}

	public UserDetails loadUserByUsername(String username)
			throws UsernameNotFoundException, DataAccessException {
		return userService.getByUsername(username);
	}

}
